using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes.DomainAttributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Enums;
using System.Collections.Generic;
using System.ComponentModel;

namespace Baci.ArcGIS._DataManagementTools._FeatureBinning
{
    /// <summary>
    /// <para>Manage Feature Bin Cache</para>
    /// <para>Manages the feature binning cache for data with feature binning enabled.</para>
    /// <para>管理启用了功能合并的数据的功能分箱缓存。</para>
    /// </summary>    
    [DisplayName("Manage Feature Bin Cache")]
    public class ManageFeatureBinCache : AbstractGPProcess
    {
        /// <summary>
        /// 无参构造
        /// </summary>
        public ManageFeatureBinCache()
        {

        }

        /// <summary>
        /// 有参构造
        /// </summary>
        /// <param name="_in_features">
        /// <para>Input Features</para>
        /// <para>The binning-enabled feature class that will have its static cache updated.</para>
        /// <para>将更新其静态缓存的已启用图格的要素类。</para>
        /// </param>
        public ManageFeatureBinCache(object _in_features)
        {
            this._in_features = _in_features;
        }
        public override string ToolboxName => "Data Management Tools";

        public override string ToolName => "Manage Feature Bin Cache";

        public override string CallName => "management.ManageFeatureBinCache";

        public override List<string> AcceptEnvironments => ["workspace"];

        public override object[] ParameterInfo => [_in_features, _bin_type.GetGPValue(), _max_lod.GetGPValue(), _add_cache_statistics, _delete_cache_statistics, _out_features];

        /// <summary>
        /// <para>Input Features</para>
        /// <para>The binning-enabled feature class that will have its static cache updated.</para>
        /// <para>将更新其静态缓存的已启用图格的要素类。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Input Features")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _in_features { get; set; }


        /// <summary>
        /// <para>Bin Type</para>
        /// <para><xdoc>
        ///   <para>Specifies the type of binning that will be enabled. If you are using SAP HANA data, only square bins are supported.</para>
        ///   <bulletList>
        ///     <bullet_item>Flat hexagon—A binning scheme that is also known as flat geohex or flat hexbinning. The tiles are a tessellation of hexagons in which the orientation of the hexagons has a flat edge of the hexagon on top. This is the default for Microsoft SQL Server, Oracle, and PostgreSQL data.</bullet_item><para/>
        ///     <bullet_item>Pointy hexagon—A binning scheme that is also known as pointy geohex or pointy hexbinning. The tiles are a tessellation of hexagons in which the orientation of the hexagons has a point of the hexagon on top.</bullet_item><para/>
        ///     <bullet_item>Square—A binning scheme in which the tiles are a tessellation of squares, also known as geosquare or squarebinning. This is the default for Db2 and SAP HANA data. This is the only bin type available for SAP HANA data.</bullet_item><para/>
        ///     <bullet_item>Geohash—A binning scheme in which the tiles are a tessellation of rectangles. Because geohash bins always use the WGS 1984 Geographic Coordinate System (GCS WGS 1984, EPSG WKID 4326), you cannot specify a bin coordinate system for geohash bins.</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>指定将启用的装箱类型。如果使用的是 SAP HANA 数据，则仅支持方形条柱。</para>
        ///   <bulletList>
        ///     <bullet_item>平面六边形 - 一种分箱方案，也称为平面六边形或平面六边形。瓷砖是六边形的镶嵌，其中六边形的方向在顶部具有六边形的平坦边缘。这是 Microsoft SQL Server、Oracle 和 PostgreSQL 数据的默认值。</bullet_item><para/>
        ///     <bullet_item>尖头六边形 - 一种分箱方案，也称为尖头地六边形或尖头六边形。瓷砖是六边形的镶嵌，其中六边形的方向在顶部有一个六边形的点。</bullet_item><para/>
        ///     <bullet_item>正方形 - 一种分箱方案，其中切片是正方形的镶嵌，也称为地理平方或正方形分箱。这是 Db2 和 SAP HANA 数据的缺省值。这是唯一可用于 SAP HANA 数据的 bin 类型。</bullet_item><para/>
        ///     <bullet_item>Geohash - 一种分箱方案，其中切片是矩形的镶嵌。由于 geohash 图格始终使用 WGS 1984 地理坐标系 （GCS WGS 1984， EPSG WKID 4326），因此无法为 geohash 图格指定图格坐标系。</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Bin Type")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public _bin_type_value? _bin_type { get; set; } = null;

        public enum _bin_type_value
        {
            /// <summary>
            /// <para>Flat hexagon</para>
            /// <para>Flat hexagon—A binning scheme that is also known as flat geohex or flat hexbinning. The tiles are a tessellation of hexagons in which the orientation of the hexagons has a flat edge of the hexagon on top. This is the default for Microsoft SQL Server, Oracle, and PostgreSQL data.</para>
            /// <para>平面六边形 - 一种分箱方案，也称为平面六边形或平面六边形。瓷砖是六边形的镶嵌，其中六边形的方向在顶部具有六边形的平坦边缘。这是 Microsoft SQL Server、Oracle 和 PostgreSQL 数据的默认值。</para>
            /// </summary>
            [Description("Flat hexagon")]
            [GPEnumValue("FLAT_HEXAGON")]
            _FLAT_HEXAGON,

            /// <summary>
            /// <para>Pointy hexagon</para>
            /// <para>Pointy hexagon—A binning scheme that is also known as pointy geohex or pointy hexbinning. The tiles are a tessellation of hexagons in which the orientation of the hexagons has a point of the hexagon on top.</para>
            /// <para>尖头六边形 - 一种分箱方案，也称为尖头地六边形或尖头六边形。瓷砖是六边形的镶嵌，其中六边形的方向在顶部有一个六边形的点。</para>
            /// </summary>
            [Description("Pointy hexagon")]
            [GPEnumValue("POINTY_HEXAGON")]
            _POINTY_HEXAGON,

            /// <summary>
            /// <para>Square</para>
            /// <para>Square—A binning scheme in which the tiles are a tessellation of squares, also known as geosquare or squarebinning. This is the default for Db2 and SAP HANA data. This is the only bin type available for SAP HANA data.</para>
            /// <para>正方形 - 一种分箱方案，其中切片是正方形的镶嵌，也称为地理平方或正方形分箱。这是 Db2 和 SAP HANA 数据的缺省值。这是唯一可用于 SAP HANA 数据的 bin 类型。</para>
            /// </summary>
            [Description("Square")]
            [GPEnumValue("SQUARE")]
            _SQUARE,

            /// <summary>
            /// <para>Geohash</para>
            /// <para>Geohash—A binning scheme in which the tiles are a tessellation of rectangles. Because geohash bins always use the WGS 1984 Geographic Coordinate System (GCS WGS 1984, EPSG WKID 4326), you cannot specify a bin coordinate system for geohash bins.</para>
            /// <para>Geohash - 一种分箱方案，其中切片是矩形的镶嵌。由于 geohash 图格始终使用 WGS 1984 地理坐标系 （GCS WGS 1984， EPSG WKID 4326），因此无法为 geohash 图格指定图格坐标系。</para>
            /// </summary>
            [Description("Geohash")]
            [GPEnumValue("GEOHASH")]
            _GEOHASH,

        }

        /// <summary>
        /// <para>Level of Detail</para>
        /// <para><xdoc>
        ///   <para>Specifies the maximum level of detail that will be used for the cache.</para>
        ///   <para>Tiling schemes are a continuum of scale ranges. Depending on your map, you may want to forego caching of some of the extremely large or small scales in your tiling scheme. This tool examines the scale dependencies in your map and attempts to provide a maximum range of scale for caching. Choose a level of detail that most closely matches the intended use of the map in which the data will be shown.</para>
        ///   <bulletList>
        ///     <bullet_item>World—A world scale will be used as the maximum level of detail.</bullet_item><para/>
        ///     <bullet_item>Continents—Multiple continents scale will be used as the maximum level of detail.</bullet_item><para/>
        ///     <bullet_item>Continent—A single continent scale will be used as the maximum level of detail.</bullet_item><para/>
        ///     <bullet_item>Countries—Multiple countries scale will be used as the maximum level of detail.</bullet_item><para/>
        ///     <bullet_item>Country—A single country scale will be used as the maximum level of detail.</bullet_item><para/>
        ///     <bullet_item>States—Multiple states scale will be used as the maximum level of detail.</bullet_item><para/>
        ///     <bullet_item>State—A single state scale will be used as the maximum level of detail.</bullet_item><para/>
        ///     <bullet_item>Counties—Multiple counties scale will be used as the maximum level of detail.</bullet_item><para/>
        ///     <bullet_item>County—A single county scale will be used as the maximum level of detail.</bullet_item><para/>
        ///     <bullet_item>Cities—Multiple cities scale will be used as the maximum level of detail.</bullet_item><para/>
        ///     <bullet_item>City—A single city scale will be used as the maximum level of detail.</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>指定将用于缓存的最大详细级别。</para>
        ///   <para>切片方案是比例范围的连续体。根据地图的不同，您可能希望放弃切片方案中某些极大或极小比例的缓存。此工具将检查地图中的比例依赖关系，并尝试为缓存提供最大比例范围。选择与显示数据的地图的预期用途最匹配的详细信息级别。</para>
        ///   <bulletList>
        ///     <bullet_item>世界 - 世界比例将用作最大细节级别。</bullet_item><para/>
        ///     <bullet_item>大洲 - 将使用多个大洲比例作为最大细节级别。</bullet_item><para/>
        ///     <bullet_item>大洲 - 将使用单个大洲比例作为最高细节级别。</bullet_item><para/>
        ///     <bullet_item>国家/地区 - 将使用多个国家/地区比例作为最高详细级别。</bullet_item><para/>
        ///     <bullet_item>国家/地区—将使用单个国家/地区比例作为最高详细级别。</bullet_item><para/>
        ///     <bullet_item>状态 - 将使用多个状态比例作为最大细节级别。</bullet_item><para/>
        ///     <bullet_item>状态 - 将使用单个状态比例作为最大细节级别。</bullet_item><para/>
        ///     <bullet_item>县 - 将使用多个县比例作为最大详细级别。</bullet_item><para/>
        ///     <bullet_item>县 - 将使用单个县比例作为最高详细级别。</bullet_item><para/>
        ///     <bullet_item>城市 - 将使用多个城市比例作为最高细节级别。</bullet_item><para/>
        ///     <bullet_item>城市 - 将使用单个城市比例作为最大细节级别。</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Level of Detail")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public _max_lod_value? _max_lod { get; set; } = null;

        public enum _max_lod_value
        {
            /// <summary>
            /// <para>World</para>
            /// <para>World—A world scale will be used as the maximum level of detail.</para>
            /// <para>世界 - 世界比例将用作最大细节级别。</para>
            /// </summary>
            [Description("World")]
            [GPEnumValue("WORLD")]
            _WORLD,

            /// <summary>
            /// <para>Continents</para>
            /// <para>Continents—Multiple continents scale will be used as the maximum level of detail.</para>
            /// <para>大洲 - 将使用多个大洲比例作为最大细节级别。</para>
            /// </summary>
            [Description("Continents")]
            [GPEnumValue("CONTINENTS")]
            _CONTINENTS,

            /// <summary>
            /// <para>Continent</para>
            /// <para>Continents—Multiple continents scale will be used as the maximum level of detail.</para>
            /// <para>大洲 - 将使用多个大洲比例作为最大细节级别。</para>
            /// </summary>
            [Description("Continent")]
            [GPEnumValue("CONTINENT")]
            _CONTINENT,

            /// <summary>
            /// <para>Countries</para>
            /// <para>Countries—Multiple countries scale will be used as the maximum level of detail.</para>
            /// <para>国家/地区 - 将使用多个国家/地区比例作为最高详细级别。</para>
            /// </summary>
            [Description("Countries")]
            [GPEnumValue("COUNTRIES")]
            _COUNTRIES,

            /// <summary>
            /// <para>Country</para>
            /// <para>Country—A single country scale will be used as the maximum level of detail.</para>
            /// <para>国家/地区—将使用单个国家/地区比例作为最高详细级别。</para>
            /// </summary>
            [Description("Country")]
            [GPEnumValue("COUNTRY")]
            _COUNTRY,

            /// <summary>
            /// <para>States</para>
            /// <para>States—Multiple states scale will be used as the maximum level of detail.</para>
            /// <para>状态 - 将使用多个状态比例作为最大细节级别。</para>
            /// </summary>
            [Description("States")]
            [GPEnumValue("STATES")]
            _STATES,

            /// <summary>
            /// <para>State</para>
            /// <para>States—Multiple states scale will be used as the maximum level of detail.</para>
            /// <para>状态 - 将使用多个状态比例作为最大细节级别。</para>
            /// </summary>
            [Description("State")]
            [GPEnumValue("STATE")]
            _STATE,

            /// <summary>
            /// <para>Counties</para>
            /// <para>Counties—Multiple counties scale will be used as the maximum level of detail.</para>
            /// <para>县 - 将使用多个县比例作为最大详细级别。</para>
            /// </summary>
            [Description("Counties")]
            [GPEnumValue("COUNTIES")]
            _COUNTIES,

            /// <summary>
            /// <para>County</para>
            /// <para>County—A single county scale will be used as the maximum level of detail.</para>
            /// <para>县 - 将使用单个县比例作为最高详细级别。</para>
            /// </summary>
            [Description("County")]
            [GPEnumValue("COUNTY")]
            _COUNTY,

            /// <summary>
            /// <para>Cities</para>
            /// <para>Cities—Multiple cities scale will be used as the maximum level of detail.</para>
            /// <para>城市 - 将使用多个城市比例作为最高细节级别。</para>
            /// </summary>
            [Description("Cities")]
            [GPEnumValue("CITIES")]
            _CITIES,

            /// <summary>
            /// <para>City</para>
            /// <para>City—A single city scale will be used as the maximum level of detail.</para>
            /// <para>城市 - 将使用单个城市比例作为最大细节级别。</para>
            /// </summary>
            [Description("City")]
            [GPEnumValue("CITY")]
            _CITY,

        }

        /// <summary>
        /// <para>Add Statistic to Cache</para>
        /// <para><xdoc>
        ///   <para>Specifies the statistics that will be summarized and stored in the bin cache. Statistics are used to symbolize bins and provide aggregate information for all the points in a bin. One summary statistic, shape_count (which is the total feature count), is always available.
        ///   <bulletList>
        ///     <bullet_item>Field—The field on which to calculate the summary statistics. Supported field types are short, long, float, and double.  </bullet_item><para/>
        ///     <bullet_item>Statistic Type—The type of statistic to calculate for the specified field. Statistics are calculated for all features in the bin. Available statistics types are as follows:
        ///       <bulletList>
        ///         <bullet_item>Mean (AVG)—Calculates the average for the specified field.      </bullet_item><para/>
        ///         <bullet_item>Minimum (MIN)—Finds the smallest value for all records of the specified field.      </bullet_item><para/>
        ///         <bullet_item>Maximum (MAX)—Finds the largest value for all records of the specified field.      </bullet_item><para/>
        ///         <bullet_item>Standard deviation (STDDEV)—Calculates the standard deviation value for the field.      </bullet_item><para/>
        ///         <bullet_item>Sum (SUM)—Adds the total value for the specified field.      </bullet_item><para/>
        ///       </bulletList>
        ///     </bullet_item><para/>
        ///   </bulletList>
        ///   </para>
        /// </xdoc></para>
        /// <para><xdoc>
        /// <para>指定将汇总并存储在 bin 缓存中的统计信息。统计数据用于对图格进行符号化，并提供图格中所有点的聚合信息。一个汇总统计量 shape_count（即要素总数）始终可用。
        ///   <bulletList>
        ///     <bullet_item>字段 - 用于计算汇总统计数据的字段。支持的字段类型包括 short、long、float 和 double。 </bullet_item><para/>
        /// <bullet_item>统计类型 - 要为指定字段计算的统计数据类型。将计算图格中所有要素的统计数据。可用的统计信息类型如下：
        ///       <bulletList>
        ///         <bullet_item>平均值 （AVG） - 计算指定字段的平均值。</bullet_item><para/>
        ///         <bullet_item>最小值 （MIN） - 查找指定字段的所有记录的最小值。</bullet_item><para/>
        ///         <bullet_item>最大值 （MAX） - 查找指定字段的所有记录的最大值。</bullet_item><para/>
        ///         <bullet_item>标准差 （STDDEV） - 计算字段的标准差值。</bullet_item><para/>
        ///         <bullet_item>Sum （SUM） - 添加指定字段的总值。</bullet_item><para/>
        ///       </bulletList>
        ///     </bullet_item><para/>
        ///   </bulletList>
        ///   </para>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Add Statistic to Cache")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _add_cache_statistics { get; set; } = null;


        /// <summary>
        /// <para>Delete Statistic from Cache</para>
        /// <para>The summary statistic that will be deleted from the cache. You cannot delete the default COUNT summary statistic.</para>
        /// <para>将从缓存中删除的汇总统计信息。您无法删除默认的 COUNT 汇总统计数据。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Delete Statistic from Cache")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public List<object> _delete_cache_statistics { get; set; } = null;


        /// <summary>
        /// <para>Updated Features</para>
        /// <para></para>
        /// <para></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Updated Features")]
        [Description("")]
        [Option(OptionTypeEnum.derived)]
        public object _out_features { get; set; }


        public ManageFeatureBinCache SetEnv(object workspace = null)
        {
            base.SetEnv(workspace: workspace);
            return this;
        }

    }

}